package com.ht.utils.config;

import java.util.HashMap;

public class WordAndHtmlConfig {
    private static final HashMap<String,String>  ZI_TI_CONFIG = new HashMap<>();
    private static final HashMap<String,String> ZI_TI_CONFIG_HTML_TO_WORD = new HashMap<>();
    static {
        ZI_TI_CONFIG.put("宋体", "SimSun");
        ZI_TI_CONFIG.put("黑体", "SimHei");
        ZI_TI_CONFIG.put("微软雅黑", "Microsoft Yahei");
        ZI_TI_CONFIG.put("微软正黑体", "Microsoft JhengHei");
        ZI_TI_CONFIG.put("楷体", "KaiTi");
        ZI_TI_CONFIG.put("新宋体", "NSimSun");
        ZI_TI_CONFIG.put("仿宋", "FangSong");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'SimSun'", "宋体");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'SimHei'", "黑体");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'Microsoft Yahei'", "微软雅黑");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'Microsoft JhengHei'", "微软正黑体");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'KaiTi'", "楷体");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'NSimSun'", "新宋体");
        ZI_TI_CONFIG_HTML_TO_WORD.put("'FangSong'", "仿宋");
    }
    public static String getZiTiByWord(String wordZiTiName){
        return ZI_TI_CONFIG.get(wordZiTiName);
    }
    public static String getWordZiTi(String htmlZiTiName){
        return ZI_TI_CONFIG_HTML_TO_WORD.get(htmlZiTiName);
    }
}
